#!/bin/bash

#
# Parameters:
#
# [sysdig path]     run backend with custom sysdig executables path
#

if [ ! -z "$1" ] && [ -e "$1" ]
then
    # or use custom path
    SYSDIG_PATH=$1
else
    SYSDIG_PATH='../../../sysdig'
fi

run() {
    cd ember-electron/backend

    npm start --- -p=${SYSDIG_PATH}

    cd ../..
}

run
